package com.xiaomo.gitee.datamanager.mapper;
import java.util.List;

import com.xiaomo.gitee.datamanager.cache.MybatisRedisCache;
import org.apache.ibatis.annotations.CacheNamespace;
import org.apache.ibatis.annotations.Param;

import com.xiaomo.gitee.datamanager.entity.Tags;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;

@Mapper
@CacheNamespace(implementation = MybatisRedisCache.class,eviction = MybatisRedisCache.class)
public interface TagsMapper extends BaseMapper<Tags> {
    @Override
    int insert(Tags entity);

    List<Tags> selectAll();
    Tags selectOneByContent(@Param("content") String content);

    Tags selectOneById(@Param("id") Long id);

    int deleteById(@Param("id") Long id);

    int updateContentById(@Param("content") String content, @Param("id") Long id);

    List<Tags> searchTagsByName(
            @Param("info") String info,
            @Param("orderBy") String orderBy
    );

}




